import java.util.*;
/**
 * This is main program which is very simple and
 * most of the work is being done by calling methods
 * from other classes.
 * @author SB
 *
 */

public class ContactList {
	public static void main(String argv[]) {
		System.out.println("#Greeting");
		Boolean quit = true;
		while(quit) {
			System.out.println("#Menu");
			Scanner input;
			input = new Scanner(System.in);
			switch (input.nextInt()) {
				case 1:
					Contact temp;
					temp = new Contact();
					temp.fillForm();
					Command.addContact(temp.getLastName());
					break;
				case 2:
					Command.printAll();
					break;
				case 3:
					Command.printContact();
					break;
				case 4:
					Command.saveChanges();
					quit = false;
					break;
			}
		}
	}
}

